Effects of Version Control System on the Efficiency of Refused Bequest Code Smell Identification Algorithm
نویسنده
چکیده
Refused bequest is a code smell that originates from introduction of inappropriate class hierarchies where subclasses do not specialize or use the functionalities provided by the parent class. The existing refused bequest code smell identification algorithms use either static analysis or a combination of static and dynamic analysis based technique. However, those algorithms do not consider version control history. If the parts that have been changed from a previous version can be considered for refused bequest identification, the identification time may be reduced. An approach is proposed here employing the version control history to reduce identification time in refused bequest code smell identification. The proposed approach has four components namely Change Collector, Source Code Parser, Error Injector and Smell Calculator. Change Collector identifies source codes that have been changed from the previous version. Source Code Parser then parses the source codes to identify metrics such as inherited method, overridden method, super classs method invocation etc. After parsing the source codes, Error Injector introduces intentional errors in the non-overridden inherited methods of the subclasses. Smell Calculator then calculates smell for each of the subclasses based on metrics identified in Source Code Parser and Error Injector. The comparative analysis of the results shows a significant improvement in execution time. The proposed approach is found to be 16.2% more time efficient than the existing approach for the sample projects. This is because the approach incorporates version control history in the identification process. Moreover, the proposed approach is able to identify code smells as accurately as the existing approach.
منابع مشابه
Cultural Adaptation of Sniffin’ Sticks Smell Identification Test: The Malaysian Version
Introduction: Sniffin’ Sticks smell identification test is a tool used for evaluation of olfactory function but the results are culture-dependent. It relies on the subject’s familiarity to the odorant and descriptors. This study aims to develop the Malaysian version of Sniffin’ Sticks smell identification test suitable for local population usage. Materials and Methods: The o...
متن کاملModeling and Identification Based On CAN Network Information in Iranian Cars
Modeling and identification of the system of Iranian cars is one of the most basic needs of automotive and consumer groups and has a broad role for safe driving. It has happened with speed increasing or changing of shift gear, effects on water temperature or the car's torque has been observed, but how much and how intensely and with what algorithm this effect is identifiable, can be modeled...
متن کاملGENERALIZED FLEXIBILITY-BASED MODEL UPDATING APPROACH VIA DEMOCRATIC PARTICLE SWARM OPTIMIZATION ALGORITHM FOR STRUCTURAL DAMAGE PROGNOSIS
This paper presents a new model updating approach for structural damage localization and quantification. Based on the Modal Assurance Criterion (MAC), a new damage-sensitive cost function is introduced by employing the main diagonal and anti-diagonal members of the calculated Generalized Flexibility Matrix (GFM) for the monitored structure and its analytical model. Then, ...
متن کاملIIR System Identification Using Improved Harmony Search Algorithm with Chaos
Due to the fact that the error surface of adaptive infinite impulse response (IIR) systems is generally nonlinear and multimodal, the conventional derivative based techniques fail when used in adaptive identification of such systems. In this case, global optimization techniques are required in order to avoid the local minima. Harmony search (HS), a musical inspired metaheuristic, is a recently ...
متن کاملOptimal Placement of Capacitor Banks Using a New Modified Version of Teaching-Learning- Based Optimization Algorithm
Meta-heuristics optimization methods are important techniques for optimal design of the engineering systems. Numerous methods, inspired by different nature phenomena, have been introduced in the literature. A new modified version of Teaching-Learning-Based Optimization (TLBO) Algorithm is introduced in this paper. TLBO, as a parameter free algorithm, is based on the learning procedure of studen...
متن کامل